# -*- coding:utf-8 -*-
import os

def dirlist(path,allfile):
    filelist = os.listdir(path)
    for filename in filelist:
        filepath = os.path.join(path, filename) 
        if os.path.isdir(filepath):  
            dirlist(filepath, allfile)  
        else:  
            allfile.append(filepath)  
    return allfile  
    
if __name__ == '__main__':
    path = unicode("F:\\", "utf-8")
    dirlist(path,[])
